
//1.导包
import Vue from 'vue'
import App from './App.vue';
import VueRouter from 'vue-router';
import VueResource from 'vue-resource';
//import VuePreview from 'vue-preview';
import iview from 'iview';
//Vue.use(VuePreview)
import '../node_modules/iview/dist/styles/iview.css';
Vue.use(iview);
// 导入样式
//导入需要的iview相关的框架

//导入我们自己的css
//import '../statics/css/site.css';

//使用我们的VueResource
Vue.use(VueResource);

//路由处理
Vue.use(VueRouter);

//创建路由https://router.vuejs.org/zh-cn/api/route-object.html
// import home from './components/home/home.vue';
// import member from './components/member/member.vue';
// import shopcart from './components/shopcart/shopcart.vue';
// import settings from './components/settings/settings.vue';
// import newslist from './components/news/newslist.vue';
// import newsinfo from './components/news/newsinfo.vue';
// import photolist from './components/photo/photolist.vue';
// import photoinfo from './components/photo/photoinfo.vue';
// import goodslist from './components/goods/goodslist.vue';
// import goodsinfo from './components/goods/goodsinfo.vue';
// import goodsdesc from './components/goods/goodsdesc.vue';
// import goodscomment from './components/goods/goodscomment.vue';

// var vueRouters = new VueRouter({
//     routes:[
//         {path:'/',redirect:'home'},
//         {name:'home',path:'/home',component:home},
//         {name:'member',path:'/member',component:member},
//         {name:'shopcart',path:'/shopcart',component:shopcart},
//         {name:'settings',path:'/settings',component:settings},
//         {name:'newslist',path:'/news/list',component:newslist},
//         {name:'newsinfo',path:'/news/info/:newsId',component:newsinfo},
//         {name:'photolist',path:'/photo/list',component:photolist},
//         {name:'photoinfo',path:'/photo/info/:photoId',component:photoinfo},
//         {name:'goodslist',path:'/goods/list',component:goodslist},
//         {name:'goodsinfo',path:'/goods/info/:goodsId',component:goodsinfo},
//         {name:'goodsdesc',path:'/goods/desc',component:goodsdesc},
//         {name:'goodscomment',path:'/goods/comment/:goodsId',component:goodscomment}
//     ],
  
 //});

//创建Vue对象
new Vue({
    el:'#app',
    // router:vueRouters,
    render:c=>c(App)//使用webpack,渲染App.vue这个根组件
})
